/**
 * 
 */
package com.csc.bankingsystem.core.service;

import java.util.Date;
import java.util.List;

import com.csc.bankingsystem.core.dto.BSPaging;
import com.csc.bankingsystem.core.entity.AccountInfo;
import com.csc.bankingsystem.core.entity.TransferRecord;
import com.csc.bankingsystem.core.entity.UserInfo;
import com.csc.bankingsystem.core.exception.NotEnoughMoneyException;

/**
 * Define service operation of TransferRecord
 * 
 * @author angelkid
 *
 */
public interface TransferRecordService {

	TransferRecord find(long id);

	List<TransferRecord> findAll();

	Long countAll();

	// void saveOrUpdate(TransferRecord transferRecord);

	Long save(TransferRecord transferRecord);

	void update(TransferRecord transferRecord);

	void delete(TransferRecord transferRecord);

	void createTransferRecord(UserInfo curUserInfo, AccountInfo source,
			AccountInfo destination, Long amount, String message)
			throws NotEnoughMoneyException;
	List<TransferRecord> findByUserInfo(BSPaging paging, UserInfo userInfo, Date toDate);
}
